import { $put, $post } from '@js/request'
import { PDFParamSchema } from '@src/components/schema/pdf';

export async function updateRequest (caseid: string, fileid: string, parameters: PDFParamSchema[], seal: string | null) {
  const res = await $put(`/api/commission/document/${caseid}/${fileid}`, {
    parameters,
    seal
  })
  return res.data
}

export async function reproductRequest (fileid: string) {
  const res = await $post('/api/commission/document/regenerate_file', {
    id: fileid
  })
  return res.data
}
